Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

replaced 'iconoir-react' with '@tokens-studio/icons' where possible #532

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

AlexBxl
Copy link
Contributor

@AlexBxl AlexBxl commented Nov 21, 2024

Description

  • replaced 'iconoir-react' with '@tokens-studio/icons' where possible

Resolves #530

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Copy link

changeset-bot bot commented Nov 21, 2024

⚠️ No Changeset found

Latest commit: d66d249

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@AlexBxl
Copy link
Contributor Author

AlexBxl commented Nov 22, 2024

Icons are now imported individually.

@@ -1,12 +1,13 @@
import { Accordion, Box, Stack, Text, TextInput } from '@tokens-studio/ui';
import { DragItem } from './DragItem.js';
import { DropPanelStore } from './data.js';
import { IconoirProvider, NavArrowRight } from 'iconoir-react';
import { IconoirProvider } from 'iconoir-react';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check where this is used, we just need a wrapper around the icons used to make sure they are the correct size

import {
PanelGroup,
PanelItem,
defaultPanelGroupsFactory,
} from '@tokens-studio/graph-editor';
import { nodeLookup as audioLookup } from '@tokens-studio/graph-engine-nodes-audio';
import { nodes as fsNodes } from '@tokens-studio/graph-engine-nodes-fs';
import Accessibility from '@tokens-studio/icons/Accessibility.js';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doesn't look like this package had the new icons package installed

@@ -1,16 +1,5 @@
'use client';

import {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here, make sure we install the icons package within this package so we don't get any surprises

added @tokens-studio/icons to vscode-extension and ui packages
<IconoirProvider
iconProps={{ width: '0.875em', height: '0.875em' }}
>
<div style={{ width: '0.875em', height: '0.875em' }}>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does the icon expand correctly into this ? I don't think it has an implicit height & width of 100%

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fyi you can just pass width and height into the icon which is the preferred way of scaling the icon as then the stroke will also adjust

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

replace iconoir with @tokens-studio/icons
4 participants